3.379 \(\int \frac{(a+b x^3) (c+d x+e x^2+f x^3+g x^4+h x^5)}{x^2} \, dx\)

Optimal. Leaf size=86 \[ \frac{1}{2} x^2 (a f+b c)+\frac{1}{3} x^3 (a g+b d)+\frac{1}{4} x^4 (a h+b e)-\frac{a c}{x}+a d \log (x)+a e x+\frac{1}{5} b f x^5+\frac{1}{6} b g x^6+\frac{1}{7} b h x^7 \]

[Out]

-((a*c)/x) + a*e*x + ((b*c + a*f)*x^2)/2 + ((b*d + a*g)*x^3)/3 + ((b*e + a*h)*x^4)/4 + (b*f*x^5)/5 + (b*g*x^6)
/6 + (b*h*x^7)/7 + a*d*Log[x]

________________________________________________________________________________________

Rubi [A]  time = 0.0662083, antiderivative size = 86, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 36, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.028, Rules used = {1820} \[ \frac{1}{2} x^2 (a f+b c)+\frac{1}{3} x^3 (a g+b d)+\frac{1}{4} x^4 (a h+b e)-\frac{a c}{x}+a d \log (x)+a e x+\frac{1}{5} b f x^5+\frac{1}{6} b g x^6+\frac{1}{7} b h x^7 \]

Antiderivative was successfully verified.

[In]

Int[((a + b*x^3)*(c + d*x + e*x^2 + f*x^3 + g*x^4 + h*x^5))/x^2,x]

[Out]

-((a*c)/x) + a*e*x + ((b*c + a*f)*x^2)/2 + ((b*d + a*g)*x^3)/3 + ((b*e + a*h)*x^4)/4 + (b*f*x^5)/5 + (b*g*x^6)
/6 + (b*h*x^7)/7 + a*d*Log[x]

Rule 1820

Int[(Pq_)*((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_.))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*Pq*(a +
 b*x^n)^p, x], x] /; FreeQ[{a, b, c, m, n}, x] && PolyQ[Pq, x] && (IGtQ[p, 0] || EqQ[n, 1])

Rubi steps

\begin{align*} \int \frac{\left (a+b x^3\right ) \left (c+d x+e x^2+f x^3+g x^4+h x^5\right )}{x^2} \, dx &=\int \left (a e+\frac{a c}{x^2}+\frac{a d}{x}+(b c+a f) x+(b d+a g) x^2+(b e+a h) x^3+b f x^4+b g x^5+b h x^6\right ) \, dx\\ &=-\frac{a c}{x}+a e x+\frac{1}{2} (b c+a f) x^2+\frac{1}{3} (b d+a g) x^3+\frac{1}{4} (b e+a h) x^4+\frac{1}{5} b f x^5+\frac{1}{6} b g x^6+\frac{1}{7} b h x^7+a d \log (x)\\ \end{align*}

Mathematica [A]  time = 0.0412215, size = 86, normalized size = 1. \[ \frac{1}{2} x^2 (a f+b c)+\frac{1}{3} x^3 (a g+b d)+\frac{1}{4} x^4 (a h+b e)-\frac{a c}{x}+a d \log (x)+a e x+\frac{1}{5} b f x^5+\frac{1}{6} b g x^6+\frac{1}{7} b h x^7 \]

Antiderivative was successfully verified.

[In]

Integrate[((a + b*x^3)*(c + d*x + e*x^2 + f*x^3 + g*x^4 + h*x^5))/x^2,x]

[Out]

-((a*c)/x) + a*e*x + ((b*c + a*f)*x^2)/2 + ((b*d + a*g)*x^3)/3 + ((b*e + a*h)*x^4)/4 + (b*f*x^5)/5 + (b*g*x^6)
/6 + (b*h*x^7)/7 + a*d*Log[x]

________________________________________________________________________________________

Maple [A]  time = 0.004, size = 81, normalized size = 0.9 \begin{align*}{\frac{bh{x}^{7}}{7}}+{\frac{bg{x}^{6}}{6}}+{\frac{bf{x}^{5}}{5}}+{\frac{{x}^{4}ah}{4}}+{\frac{be{x}^{4}}{4}}+{\frac{{x}^{3}ag}{3}}+{\frac{bd{x}^{3}}{3}}+{\frac{af{x}^{2}}{2}}+{\frac{bc{x}^{2}}{2}}+aex+ad\ln \left ( x \right ) -{\frac{ac}{x}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((b*x^3+a)*(h*x^5+g*x^4+f*x^3+e*x^2+d*x+c)/x^2,x)

[Out]

1/7*b*h*x^7+1/6*b*g*x^6+1/5*b*f*x^5+1/4*x^4*a*h+1/4*b*e*x^4+1/3*x^3*a*g+1/3*b*d*x^3+1/2*a*f*x^2+1/2*b*c*x^2+a*
e*x+a*d*ln(x)-a*c/x

________________________________________________________________________________________

Maxima [A]  time = 0.9478, size = 100, normalized size = 1.16 \begin{align*} \frac{1}{7} \, b h x^{7} + \frac{1}{6} \, b g x^{6} + \frac{1}{5} \, b f x^{5} + \frac{1}{4} \,{\left (b e + a h\right )} x^{4} + \frac{1}{3} \,{\left (b d + a g\right )} x^{3} + a e x + \frac{1}{2} \,{\left (b c + a f\right )} x^{2} + a d \log \left (x\right ) - \frac{a c}{x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x^3+a)*(h*x^5+g*x^4+f*x^3+e*x^2+d*x+c)/x^2,x, algorithm="maxima")

[Out]

1/7*b*h*x^7 + 1/6*b*g*x^6 + 1/5*b*f*x^5 + 1/4*(b*e + a*h)*x^4 + 1/3*(b*d + a*g)*x^3 + a*e*x + 1/2*(b*c + a*f)*
x^2 + a*d*log(x) - a*c/x

________________________________________________________________________________________

Fricas [A]  time = 1.02038, size = 212, normalized size = 2.47 \begin{align*} \frac{60 \, b h x^{8} + 70 \, b g x^{7} + 84 \, b f x^{6} + 105 \,{\left (b e + a h\right )} x^{5} + 140 \,{\left (b d + a g\right )} x^{4} + 420 \, a e x^{2} + 210 \,{\left (b c + a f\right )} x^{3} + 420 \, a d x \log \left (x\right ) - 420 \, a c}{420 \, x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x^3+a)*(h*x^5+g*x^4+f*x^3+e*x^2+d*x+c)/x^2,x, algorithm="fricas")

[Out]

1/420*(60*b*h*x^8 + 70*b*g*x^7 + 84*b*f*x^6 + 105*(b*e + a*h)*x^5 + 140*(b*d + a*g)*x^4 + 420*a*e*x^2 + 210*(b
*c + a*f)*x^3 + 420*a*d*x*log(x) - 420*a*c)/x

________________________________________________________________________________________

Sympy [A]  time = 0.347942, size = 82, normalized size = 0.95 \begin{align*} - \frac{a c}{x} + a d \log{\left (x \right )} + a e x + \frac{b f x^{5}}{5} + \frac{b g x^{6}}{6} + \frac{b h x^{7}}{7} + x^{4} \left (\frac{a h}{4} + \frac{b e}{4}\right ) + x^{3} \left (\frac{a g}{3} + \frac{b d}{3}\right ) + x^{2} \left (\frac{a f}{2} + \frac{b c}{2}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x**3+a)*(h*x**5+g*x**4+f*x**3+e*x**2+d*x+c)/x**2,x)

[Out]

-a*c/x + a*d*log(x) + a*e*x + b*f*x**5/5 + b*g*x**6/6 + b*h*x**7/7 + x**4*(a*h/4 + b*e/4) + x**3*(a*g/3 + b*d/
3) + x**2*(a*f/2 + b*c/2)

________________________________________________________________________________________

Giac [A]  time = 1.07097, size = 112, normalized size = 1.3 \begin{align*} \frac{1}{7} \, b h x^{7} + \frac{1}{6} \, b g x^{6} + \frac{1}{5} \, b f x^{5} + \frac{1}{4} \, a h x^{4} + \frac{1}{4} \, b x^{4} e + \frac{1}{3} \, b d x^{3} + \frac{1}{3} \, a g x^{3} + \frac{1}{2} \, b c x^{2} + \frac{1}{2} \, a f x^{2} + a x e + a d \log \left ({\left | x \right |}\right ) - \frac{a c}{x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x^3+a)*(h*x^5+g*x^4+f*x^3+e*x^2+d*x+c)/x^2,x, algorithm="giac")

[Out]

1/7*b*h*x^7 + 1/6*b*g*x^6 + 1/5*b*f*x^5 + 1/4*a*h*x^4 + 1/4*b*x^4*e + 1/3*b*d*x^3 + 1/3*a*g*x^3 + 1/2*b*c*x^2
+ 1/2*a*f*x^2 + a*x*e + a*d*log(abs(x)) - a*c/x